import request from '@/utils/request';

// 数据服务列表 /system/permission/list
export function getServiceList (query) {
  return request({
    url: "/system/permission/list",
    method: "get",
    params: query
  });
}

// 数据服务详细数据 /system/permission/getinfo
export function getServiceInfo (id) {
  return request({
    url: `/system/permission/getinfo/${id}`,
    method: "get",
  });
}

// 删除 /system/permission/remove
export function removeServiceItem (ids) {
  return request({
    url: `/system/permission/remove/${ids}`,
    method: "get",
  });
}

// 编辑 /system/permission/edit
export function editServiceItem (data) {
  return request({
    url: "/system/permission/edit",
    method: "post",
    data
  });
}

// 新增 /system/permission/add
export function addServiceItem (data) {
  return request({
    url: "/system/permission/add",
    method: "post",
    data
  });
}
